﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using CSP.Bll.CommonBll;
using CSP.Bll.IObjectBlls;
using CSP.Dao.IObjectDaos.CSP;
using CSP.Common.Factories;
using CSP.Dao;

namespace CSP.Bll.ObjectBlls
{
    public class RateStatisticBll : CSPCommonBll, IRateStatisticBll
    {
        /// <summary>
        /// 缓存键值
        /// </summary>
        private const string CACHEKEY = "RateStatistic_";

        private IRateStatisticDao _rateStatisticDao;

        public RateStatisticBll()
        {
            _cacheProvider = CachedProviderFactory.GetMemCachedProvider();
            _rateStatisticDao = CSPDaoFactory.GetInstance().GetRateStatisticDao();
        }

        public ICollection<Model.CSP.RateStatistic> GetRateStatisticsByUser(string userName)
        {
            return _rateStatisticDao.GetRateStatisticsByUser(userName);
        }
    }
}
